package com.zhiyou100.blog.listener;

import com.zhiyou100.blog.aciton.title.TitlePagingServlet;
import com.zhiyou100.blog.entity.PageBean;
import com.zhiyou100.blog.entity.Title;
import com.zhiyou100.blog.service.TitleService;

import javax.servlet.ServletContextEvent;
import javax.servlet.ServletContextListener;
import javax.servlet.annotation.WebListener;

/**
 * @author shkstart
 * @create 2021-10-22 23:20
 * 出于性能考虑，不设置这样的
 */
//@WebListener("/*")
public class TitleListener/* implements ServletContextListener*/ {
//    private TitleService service = new TitleService();


//    @Override
//    public void contextInitialized(ServletContextEvent sce) {
////        PageBean<Title> titlePage = service.getListTitlePaging(1);
//        sce.getServletContext().setAttribute("init", 1);
//        System.out.println("contextInitialized 方法执行了");
//    }
}
